We give a detailed and mainly geometric proof of a theorem by N.N. Nekhoroshev for hamiltonian systems in $n$ degrees of freedom with $k$ constants of motion in involution, where $1 \le k \le n$. This states persistence of $k$-dimensional invariant tori, and local existence of partial action-angle coordinates, under suitable nondegeneracy conditions. Thus it admits as special cases the Poincar\'e-Lyapounov theorem (corresponding to $k=1$) and the Liouville-Arnold one (corresponding to $k = n$), and interpolates between them. The crucial tool for the proof is a generalization of the Poincar\'e map, also introduced by Nekhoroshev.